<?php if ( ! defined('ABSPATH')) exit('restricted access');

/** Theme settings note: don't remove it */
define('THEME_NAME', 'welcare');
define('FRAME_WORK', 'Version 1.4');

/** Initialize the WPnukes Apanel */
require_once('includes/launcher.php');

get_template_part('theme_functions');

/** Load the default functions after theme setup */
add_action('after_setup_theme', 'wl_theme_setup');

function wl_theme_setup()
{
	/** Add languages support */
	load_theme_textdomain(THEME_NAME, THEME_PATH .'/languages');
	
	add_editor_style();
	
	/** Register wp_nav_menus */
	if(function_exists('register_nav_menu'))
	{
		register_nav_menus(
			array(
				/** Register Main Menu location header */
				'header_menu' => __('Header Menu', THEME_NAME),
			)
		);
	}
}

/** Set the width of images and content. Should be equal to the width the theme	*/
$content = (isset($content_width)) ? $content_width : 613;

/** Post thumnail Support and add new sizes that themes is required */
add_theme_support('post-thumbnails');
add_theme_support( 'automatic-feed-links' );
add_image_size( 'post-image1', 363, 201, true );
add_image_size( 'post-image2', 613, 228, true );
add_image_size( 'post-image3', 306, 140, true );
add_image_size( 'post-image4', 154, 90, true );
add_image_size( 'single-image', 612, 285, true );
add_image_size( 'post-thumb', 59, 59, true );
add_image_size( 'gallery-image1', 183, 109, true );
add_image_size( 'gallery-image2', 110, 86, true );
add_image_size( 'gallery-thumb', 66, 66, true );
add_image_size( 'megamenu-top', 215, 104, true );


/** include theme scripts and styles */
get_template_part('libs/scripts_styles');

/** include theme metaboxes */
get_template_part('libs/meta_boxes');

/** include theme register sidebars */
get_template_part('libs/register_sidebars');

/** include theme widgets */
get_template_part('libs/theme_widgets');

/** include theme breadcrumbs */
get_template_part('libs/breadcrumbs');

get_template_part('libs/ajax_handler');